updating oE days_in_year
days_in_year
include datetime.e namespace datetime public function days_in_year(datetime dt)
returns the number of days in the year of dt.
Comments:
This takes into account leap year.
Parameters:
- dt : a datetime to be queried.
Example 1:
d = new(2007, 1, 1, 0, 0, 0) ? days_in_year(d) -- 365 d = new(2008, 1, 1, 0, 0, 0) -- leap year ? days_in_year(d) -- 366
See Also:
Not Categorized, Please Help
|